<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="/WEB-INF/tld/c.tld" prefix="c"%>
<%@ taglib uri="/WEB-INF/tld/ui.tld" prefix="ui" %>
<%
	String path = request.getContextPath();
%>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="renderer" content="webkit">
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>项目基本信息页面</title>
	<jsp:include page="../../import.jsp" flush="true" />
</head>
<body class="iframeBody">
	<div class="Wrapper">
		<div>
			<form id="fnc_prj_bsc_info_form" >
				<div class="fieldset1 tabel_col clearFix">
					<div class="fieldBox col_50">
						<div class="label">项目名称:</div>
						<div class="field">
							<span id="fncprjnm" name="fncprjnm">&nbsp;${fncPrjBscInfo.fncprjnm}</span>
						</div>
					</div>
					<div class="fieldBox col_50">
						<div class="label">金融机构</div>
						<div class="field">
							<span id="fncinsNM" name="fncinsNM">&nbsp;${fncPrjBscInfo.fncinsNM}</span>
						</div> 
					</div>
					<div class="fieldBox col_50">
						<div class="label">金融机构类型</div>
                    	<div class="field">
							<span id="instypeNM" name="instypeNM">&nbsp;${fncPrjBscInfo.instypeNM}</span>
						</div>
					</div>
					<div class="fieldBox col_50">
						<div class="label">融资报价</div>
						<div class="field">
							<span id="fncscmNM" name="fncscmNM">&nbsp;${fncPrjBscInfo.fncscmNM}</span>
						</div>
					</div>
					<div class="fieldBox col_50">
						<div class="label">国家</div>
						<div class="field">
							<span id="countryNM" name="countryNM">&nbsp;${fncPrjBscInfo.countryNM}</span>
						</div>
					</div>
					<div class="fieldBox col_50">
						<div class="label">业务类型</div>
						<div class="field">
							<span id="bustypeNM" name="bustypeNM">&nbsp;${fncPrjBscInfo.bustypeNM}</span>
						</div>
					</div>
					<div class="fieldBox col_50">
						<div class="label">项目金额</div>
						<div class="field">
							<span id="fncprjamt" name="fncprjamt">&nbsp;${fncPrjBscInfo.fncprjamt/100}</span>
						</div>
					</div> 
					<div class="fieldBox col_50">
						<div class="label">融资金额</div>
						<div class="field">
							<span id="fncfiamt" name="fncfiamt">&nbsp;${fncPrjBscInfo.fncfiamt/100}</span>
						</div>
					</div>
					<div class="fieldBox col_50">
						<div class="label">支付表数量</div>
						<div class="field">
							<span id="paySchCount" name="paySchCount">&nbsp;${fncPrjBscInfo.paySchCount}</span>
						</div>
					</div>   
					<div class="fieldBox col_50">
						<div class="label">折扣率</div>
						<div class="field">
							<span id="dcnRate" name="dcnRate">&nbsp;${fncPrjBscInfo.dcnRate*100}%</span>
						</div>
					</div>
					
					<c:if test="${not empty fncPrjBscInfo.expwdamt}"> 
						<div class="fieldBox col_50">
							<div class="label">预放款金额</div>
							<div class="field">
								<span id="expwdamt" name="expwdamt">&nbsp;${fncPrjBscInfo.expwdamt/100}</span>
							</div>
						</div> 
						<div class="fieldBox col_50">
							<div class="label">预放款日期</div>
							<div class="field">
								<span id="expwddate" name="expwddate">&nbsp;${fncPrjBscInfo.expwddate}</span>
							</div>
						</div> 
						<div class="fieldBox col_50">
							<div class="label">预放款收款账号</div>
							<div class="field">
								<span id="expwdacc" name="expwdacc">&nbsp;${fncPrjBscInfo.expwdaccNM}</span>
							</div>
						</div>  
						<div class="fieldBox col_50">
							<div class="label">预放款收款银行</div>
							<div class="field">
								<span id="expwdbank" name="expwdbank">&nbsp;${fncPrjBscInfo.expwdbank}</span>
							</div>
						</div>            
					</c:if>
					
					<c:if test="${not empty fncPrjBscInfo.acFiAmt}">
						<div class="fieldBox col_50">
							<div class="label">实际融资金额</div>
							<div class="field">
								<span id="acFiAmt" name="acFiAmt">&nbsp;${fncPrjBscInfo.acFiAmt/100}</span>
							</div>
						</div> 
						<div class="fieldBox col_50">
							<div class="label">首付款金额</div>
							<div class="field">
								<span id="fstpyamtall" name="fstpyamt">&nbsp;${fncPrjBscInfo.fstpyamtall/100}</span>
							</div>
						</div>
					</c:if>  
				</div>
			</form>
		</div>
	</div>
    
	<script type="text/javascript">
		var pageInApp={
				flag:true
			};
		$(function () {
			initTab();
		    $("#fncfiamt").html(fmoney(new  Number("${fncPrjBscInfo.fncfiamt/100}"), 2));
		    $("#fncprjamt").html(fmoney(new  Number("${fncPrjBscInfo.fncprjamt/100}"), 2));
		    $("#acFiAmt").html(fmoney(new  Number("${fncPrjBscInfo.acFiAmt/100}"), 2));
		    $("#fstpyamt").html(fmoney(new  Number("${fncPrjBscInfo.fstpyamt/100}"), 2));
		    $("#expwdamt").html(fmoney(new  Number("${fncPrjBscInfo.expwdamt/100}"), 2));
		    
		    var expwddate ="${fncPrjBscInfo.expwddate}";
			if(null != expwddate&&expwddate!=''){
				var date = new Date(expwddate);
				$("#expwddate").text(DateUtils.formatDate(date, DateUtils.YYYY_MM_DD));
			}
		
		});
		
		//格式化钱
	    function fmoney(s, n)   
		{   
		   n = n > 0 && n <= 20 ? n : 2;   
		   s = parseFloat((s + "").replace(/[^\d\.-]/g, "")).toFixed(n) + "";   
		   var l = s.split(".")[0].split("").reverse(),   
		   r = s.split(".")[1];   
		   t = "";   
		   for(var i = 0; i < l.length; i ++ )   
		   {   
		      t += l[i] + ((i + 1) % 3 == 0 && (i + 1) != l.length ? "," : "");   
		   }   
		   return t.split("").reverse().join("") + "." + r;   
		} 
	</script>
</body>
</html>